/**
 * For more configuration, please refer to https://angular.io/guide/build#proxying-to-a-backend-server
 *
 * 更多配置描述请参考 https://angular.cn/guide/build#proxying-to-a-backend-server
 *
 * Note: The proxy is only valid for real requests, Mock does not actually generate requests, so the priority of Mock will be higher than the proxy
 */
module.exports = {
  /**
   * The following means that all requests are directed to the backend `https://localhost:9000/`
   */
  // '/api': {
  //   target: 'https://localhost:9000/',
  //   secure: false, // Ignore invalid SSL certificates
  //   changeOrigin: true
  // }
  // '/': {
  //   target: 'https://localhost:9000/',
  //   secure: false, // Ignore invalid SSL certificates
  //   changeOrigin: true
  // }
  // "/api/core-auth": {
  //   "target": "http://localhost:8081",
  //   "secure": false,
  //   "pathRewrite": { "^/api/core-auth": "" },
  //   "logLevel": "debug",
  //   "changeOrigin": true
  // },    
  // "/api/core-user": {
  //   "target": "http://localhost:8082",
  //   "secure": false,
  //   "pathRewrite": { "^/api/core-user": "" },
  //   "logLevel": "debug",
  //   "changeOrigin": true
  // },  
  "/api/code-generator": {
    "target": "http://localhost:8081",
    "secure": false,
    "pathRewrite": { "^/api/code-generator": "" },
    "logLevel": "debug",
    "changeOrigin": true
  },
  "/api/schedule": {
    "target": "http://localhost:8081",
    "pathRewrite": { "^/api/schedule": "" },
    "secure": false,
    "logLevel": "debug",
    "changeOrigin": true
  },
  "/api/demo": {
    "target": "http://localhost:8081",
    "pathRewrite": { "^/api/demo": "" },
    "secure": false,
    "logLevel": "debug",
    "changeOrigin": true
  },
  // "/api/code-tea": {
  //   "target": "http://localhost:8081",
  //   "secure": false,
  //   "pathRewrite": { "^/api/code-tea": "" },
  //   "logLevel": "debug",
  //   "changeOrigin": true
  // },
  // "/api/crab-growth": {
  //   "target": "http://localhost:8084",
  //   "secure": false,
  //   "pathRewrite": { "^/api/crab-growth": "" },
  //   "logLevel": "debug",
  //   "changeOrigin": true
  // },
  "/api": {
    "target": "http://10.10.1.34:8080",
    "secure": false,
    "pathRewrite": { "^/api": "" },
    "logLevel": "debug"
  }      
};
